package org.example;
import org.example.Entity.Course;
import org.example.Entity.Student;
import org.example.controller.GradeController;
import org.example.controller.UserOne;

import java.util.List;
import java.util.Scanner;

public class main1 {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
//        System.out.println("请输入学生名字");
//        String name = scanner.nextLine();
        System.out.println("请输入学生学号：");
        String course = scanner.nextLine();
//        System.out.println("请输入课程名字");
//        String courseName=scanner.nextLine();
//        System.out.println("请输入学生平时成绩：");
//        double usually = scanner.nextDouble();
//        System.out.println("请输入学生考试成绩：");
//        double examination = scanner.nextDouble();
//        System.out.println("请输入课程id：");
//        int ids = scanner.nextInt();
        GradeController gradeController = new GradeController();
//        List<Student> students = gradeController.selectByGradeOne(course);
//        UserOne userOne = new UserOne();
//        int i = userOne.selectStudent(name);
//        Student i1 = userOne.selectStudents(name);
        List<Student> students = gradeController.selectByGradeStudent(1, 2, course);
        System.out.println(students);
//        System.out.println(students);
//        int i = gradeController.insertByDate(name, course, courseName, usually, examination);
//        if (i > 0) {
//            System.out.println("成功");
//        }else {
//            System.out.println("失败");
//        }
    }
}
